<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        /* 
            单选按钮或多选按钮被选中时触发的伪类
        */
        input:checked {
            box-shadow: 2px 2px 2px red;
        }
    </style>
</head>
<body>
    <input type="radio" name="sex">男
    <input type="radio" name="sex">女 <br>
    <input type="checkbox"> html
    <input type="checkbox"> css
    <input type="checkbox"> js
</body>
</html>